﻿@using Eking.Framework
@model eNote.Models.NoteViewModel
@{    
    Style.RequireSimple("NoteItemEditor.css");

    Script.Require("jquery.unobtrusive-ajax.min.js").AtHead();
    Script.Require("MicrosoftAjax.js").AtHead();
    Script.Require("MicrosoftMvcAjax.js").AtHead();
    Script.Require("MicrosoftMvcValidation.js").AtHead();
    Script.Require("jQueryUI_Selectable").AtHead();
    Script.RequireSimple("jquery.ba-resize.min.js", "jQueryUI_Resizable", "jXamlGrid.js", "JsUtil.js", "NoteItemEditor.js", "eNodeCodeBehind.js");
}
<script type="text/javascript">
    function onsaved() {
        alert('Saved');
    }
    function onfailsave() {
        alert('Failure')
    }
</script>
<style>
    
</style>
<div class="eNote">
    <section style="height: 30px; margin-top: 10px">
        @Html.ActionLink("NOTE", "Index")
        @Html.ActionLink("VOCA", "GetNoteView", new { f = "voca", flexMode = true })
    </section>
    <section>    
        <h1 style="font-weight: bold">
            File: @Model.FName
            <img alt="" id="loadingItem" src="/Modules/eNote/Styles/loading.gif" style="visibility: hidden" />
        </h1>
        @*<div>
            <div class="resizable" style="padding: 5px; background: gray; width:400px; height:400px">
                <div class="jXamlGrid" data-grid="0" style="height: 400px;">
                    <div data-gridrow="0" data-gridcolumn="1" data-gridcolumnspan="1" data-gridrowspan="2"
                        style="background: red">
                        CELL1.1</div>
                    <div>
                        CELL1.2</div>
                    <div>
                        CELL2.1</div>
                    <div>
                        CELL2.2</div>
                </div>
            </div>
        </div>*@
        <div class="NoteItemEditor-addDiv jXamlGrid0">
            <input data-gridColumn="0" data-gridRow="0" class="button NoteItemEditor-button" type="button" value="ADD" style="float: left;" id="addItem" data-FName = "@Model.FName" />
            <input data-gridColumn="1" data-gridRow="0" data-gridMargin="0px,4px,0px,4px" type="text" style="float: left" class="NoteItemEditor-edit" id="newItemVal" />
        </div>
        <div id="noteItems" class="jLayout">
            @Html.Partial("NoteItemView", Model.NoteItems)
        </div>
    </section>
</div>
